package interfaces;

import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.*;

public class IAlteraUsuario {

private JLabel label;
private JLabel nome;
private JLabel senha;
private JPasswordField textSenha;
private JLabel email;
private JLabel descricao;
private JTextField textNome;
private JTextField textEmail;
private JTextArea textDescricao;
private JScrollPane scrollDescricao;
private JButton voltar;
private JButton salvar;


public IAlteraUsuario(){
FlowLayout layout = new FlowLayout(FlowLayout.LEFT);

label = new JLabel("              Por favor insira seus novos dados.       ");
nome = new JLabel("Nome");
senha = new JLabel("Senha");
email = new JLabel("Email");
descricao = new JLabel("Descricao");

textSenha = new JPasswordField(23);
textSenha.setEchoChar('*');
textNome = new JTextField(23);
textEmail = new JTextField(23);
textDescricao = new JTextArea(10,23);
textDescricao.setLineWrap(true);

scrollDescricao = new JScrollPane(textDescricao,
JScrollPane.VERTICAL_SCROLLBAR_ALWAYS,
JScrollPane.HORIZONTAL_SCROLLBAR_NEVER);

voltar = new JButton("Voltar");
salvar = new JButton("Salvar");


JPanel pane = new JPanel(layout);

pane.add(label);
pane.add(new JLabel("                                                                                        "));
pane.add(nome);
pane.add(textNome);
pane.add(senha);
pane.add(textSenha);
pane.add(email);
pane.add(textEmail);
pane.add(descricao);
pane.add(scrollDescricao);
pane.add(salvar);
pane.add(voltar);

JFrame frame = new JFrame("Altera Usuario");

frame.setContentPane(pane);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setSize(300, 450);
frame.setResizable(false);
frame.setVisible(true);
}

public static void main(String[] args){
IAlteraUsuario u = new IAlteraUsuario();
}

}
